import request from '../utils/request'

const baseUrl = 'recent_connect'

export function addRecentConnect(connectionId) {
    return request({
        url: baseUrl + '/addRecentConnect',
        method: 'post',
        data: {
            connectionId: connectionId
        }
    })
}

export function removeAllRecentConnect() {
    return request({
        url: baseUrl + '/removeAllRecentConnect',
        method: 'post',
        data: {}
    })
}

export function removeRecentConnects(ids) {
    return request({
        url: baseUrl + '/removeRecentConnects',
        method: 'post',
        data: {
            ids: ids.toString()
        }
    })
}

export function getAllRecentConnectList() {
    return request({
        url: baseUrl + '/getAllRecentConnectList',
        method: 'get',
        params: {}
    })
}